package cn.ssq.service.impl;

import cn.ssq.dao.CropCpeciesMapper;
import cn.ssq.domain.CropCpecies;
import cn.ssq.service.CropCpeciesService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class CropCpeciesServiceImpl implements CropCpeciesService {
    @Autowired
    private CropCpeciesMapper cropCpeciesMapper;

    /**
     * 根据农产品的cid查询品种信息
     * @param
     * @return
     */
    @Override
    public List<CropCpecies> findCropCpeciesById( ) {
        List<CropCpecies> cropCpeciesList = cropCpeciesMapper.selectCropCpecisByCid();
        return cropCpeciesList;
    }

    @Override
    public List<CropCpecies> findCropCpeciesLIst() {
        return cropCpeciesMapper.selectCropCpeciesLIst();
    }

    @Override
    public int findByCropCpecies(String cropCpecies) {

       return cropCpeciesMapper.selectByCropCpecies(cropCpecies);
    }


}
